<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>

<!-- becomes the css class of the li element -->
<c:set var="is_empl_edit_mode" value="true" scope="request"/>

<html>
	<head>
		<title>Edit Employee</title>
		<link rel="stylesheet" type="text/css" href="css/datepicker/datepicker.css" />
		<script type="text/javascript" src="<c:out value='js/datepicker.js'/>"></script>
	</head>

	<body>
		<form:form method="POST" commandName="employee">
			<div class="column left">
				<p>
					<label for="sirName">Sir Name:</label>
					<form:input path="sirName" cssClass="text"/>
					<span class="info">Ex: Popescu</span>
				</p>
				<p>
					<label for=firstName>First Name:</label>
					<form:input path="firstName" cssClass="text"/>
					<span class="info">Ex: Ion</span>
				</p>
				<p>
					<label for="phoneNumber">Phone Number:</label>
					<form:input path="phoneNumber" cssClass="text"/>
					<span class="info">Ex: 0722900911</span>
				</p>
				<p>
					<label for="address">Address:</label>
					<form:textarea path="address" cssClass="text"/>
					<span class="info">Ex: Streat..., City ...</span>
				</p>			
				<p>
					<input type="submit" value="Submit">
					or
					<a href="<c:url value='employees.htm'/>">Cancel</a>
				</p>
			</div>
			<div class="column right">
				<p>
					<label for="hireDate">Hire Date:</label>
					<form:input path="hireDate" cssClass="text" onclick="displayDatePicker('hireDate', this);"/>
					<span class="info">Please select</span>
				</p>
				
				<p>
					<label for="qualification">Qualification:</label>
					<form:select path="qualification" cssClass="text">
						<form:option value="Captain"/>
						<form:option value="Chief Officer"/>
						<form:option value="Second officer"/>
						<form:option value="Third officer"/>
						<form:option value="Boatswain"/> <!-- marinar necalificat -->
						<form:option value="Able seaman"/>
						<form:option value="Ordinary seaman"/>
						<form:option value="Chief engineer"/>
						<form:option value="Second engineer"/>
						<form:option value="Third engineer"/>
						<form:option value="Fourth engineer"/>
						<form:option value="Engineering cadet"/>
						<form:option value="Chief steward"/>
						<form:option value="Chief cook"/>
					</form:select>
					<span class="info">Please select</span>
				</p>
				<p>
					<label for="function">Current Position:</label>
					<form:select path="function" cssClass="text">
						<form:option value="Captain"/>
						<form:option value="Chief Officer"/>
						<form:option value="Second officer"/>
						<form:option value="Third officer"/>
						<form:option value="Boatswain"/>
						<form:option value="Able seaman"/>
						<form:option value="Ordinary seaman"/>
						<form:option value="Chief engineer"/>
						<form:option value="Second engineer"/>
						<form:option value="Third engineer"/>
						<form:option value="Fourth engineer"/>
						<form:option value="Engineering cadet"/>
						<form:option value="Chief steward"/>
						<form:option value="Chief cook"/>
					</form:select>
					<span class="info">Please select</span>
				</p>
				<p>
					<label for="ship">Ship:</label>
					<form:select cssClass="text" path="ship" items="${ships}" itemLabel="name" itemValue="id"/>
					<span class="info">Please select</span>
				</p>
				<p>
					<label for="salary">Salary:</label>
					<form:input path="salary" cssClass="text"/>
					<span class="info">Ex: 1000</span>
				</p>
			</div>
			<div class="clear"></div>
		</form:form>
	</body>
</html>